﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace SWENAssignment
{
    public partial class searchStaffProfileSuccessfully : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            lblStaffID.Text = (string)Session["staffId"];
            if (!Page.IsPostBack)
            {
                staffDetails s = DBmanager.getByStaffId(lblStaffID.Text);
                lblStaffID.Text = s.StaffId;
                lblLastName.Text = s.lastName;
                lblFirstName.Text = s.firstName;
                lblNRIC.Text = s.nric;
                lblDOB.Text = s.dob.ToString("dd/MM/yyyy");
                lblContactNo.Text = s.ContactNumber.ToString();
                lblAddress.Text = s.address;
                lblEmail.Text = s.email;
                lblGender.Text = s.gender;
                lblBankAccType.Text = s.bankAccType;
                lblBankAccNo.Text = s.bankAccNumber;
                lblDutyType.Text = s.dutyType;
            }
        }

        protected void btnBack_Click(object sender, EventArgs e)
        {
            Server.Transfer("retrieveStaffProfile1.aspx?");
        }
    }
}